import requests
from config import urlConfig

class openQ :
   
   def __init__(self) :
      self.url = urlConfig.url
      self.headers = urlConfig.headers
      self.mode = urlConfig.mode
      self.payload = urlConfig.payload

   def get_position(self):
      response = requests.request(method=self.mode, url= self.url, headers= self.headers, data=self.payload)
      return response.json()
   
   def print_data(self):
      data = self.get_position()
      return data
